package com.ruoyi.logistic.service.impl;

import com.github.pagehelper.PageHelper;
import com.ruoyi.logistic.domain.NetworkStorageCharge;
import com.ruoyi.logistic.domain.PageDate;
import com.ruoyi.logistic.domain.vo.NetworkStorageChargeVo;
import com.ruoyi.logistic.mapper.NetworkStorageChargeMapper;
import com.ruoyi.logistic.service.NetworkStorageChargeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class NetworkStorageChargeServiceImpl implements NetworkStorageChargeService {
    @Autowired
    private NetworkStorageChargeMapper networkStorageChargeMapper;

    @Override
    public List<NetworkStorageCharge> selectAll(PageDate pageDate) {
        PageHelper.startPage(pageDate);
        return networkStorageChargeMapper.selectAll();
    }

    @Override
    public Boolean insert(NetworkStorageCharge networkStorageCharge) {
        return networkStorageChargeMapper.insert(networkStorageCharge);
    }

    @Override
    public Boolean update(NetworkStorageCharge networkStorageCharge) {
        return networkStorageChargeMapper.update(networkStorageCharge);
    }

    @Override
    public Boolean deleteByIds(Integer[] ids) {
        return networkStorageChargeMapper.deleteByIds(ids);
    }

    @Override
    public NetworkStorageCharge findById(Integer id) {
        return networkStorageChargeMapper.findById(id);
    }

    @Override
    public List<NetworkStorageCharge> search(NetworkStorageChargeVo networkStorageChargeVo) {
        PageHelper.startPage(networkStorageChargeVo.getPageDate());
        return networkStorageChargeMapper.search(networkStorageChargeVo);
    }


}
